package com.kun.admin.authority.service;

import com.kun.admin.authority.model.Department;

/**
 * @author likun
 * 2018/5/22 11:16
 **/
public interface DepartmentService {
    /**
     * 查找所有的部门并组装成树状结构
     * @return
     */
    Department findAllDepartmentTree();

    /**
     * 添加部门
     * @param name
     * @param parentId
     * @return
     */
    boolean addDepartment(String name, Long parentId);

    /**
     * 修改部门信息
     * @param id
     * @param name
     * @return
     */
    boolean editDepartment(Long id, String name);

    /**
     * 删除部门
     * @param id
     * @return
     */
    boolean deleteDepartment(Long id);
}
